/*

 *  
 */

package com.ruifu.common.feign.factory;

import com.ruifu.common.feign.RemoteActService;
import com.ruifu.common.feign.fallback.RemoteActServiceFallbackImpl;
import feign.hystrix.FallbackFactory;
import org.springframework.stereotype.Component;


/**
 * @author liun
 * @date 2020/5/6
 */
@Component
public class RemoteActServiceFallbackFactory implements FallbackFactory<RemoteActService> {

	@Override
	public RemoteActService create(Throwable throwable) {
		RemoteActServiceFallbackImpl remoteActServiceFallback = new RemoteActServiceFallbackImpl();
		remoteActServiceFallback.setCause(throwable);
		return remoteActServiceFallback;
	}
}
